﻿@using SeagullConsulting.MvcAjaxControls.Web.Mvc.Helpers
@using SeagullConsulting.MvcAjaxControls.Web.UI.Controllers;
@{
    ViewBag.Title = "Index";
}

<h2>AjaxDropdown</h2>

<div>
    City:@(Html.AjaxDropdown("Cities").Controller<AjaxDropdownController>().Parent("States").ToHtml())
</div>
<br />
<div>
    State:@(Html.AjaxDropdown("States").Parent("Countries").ToHtml())
</div>
<br />
<div>
    Country:@(Html.AjaxDropdown("Countries").ToHtml())
</div>
<br />
Here is the State dropdown list with a Country filter specified for USA(1).
<br />
<br />
<p>
    State:@(Html.AjaxDropdown("States2")
        .Controller<AjaxDropdownController>()
        .Filter("1")
        .ToHtml())
</p>
Here is the City dropdown list with an initial value of Tampa(1) and a State filter specified for FL(1).
<br />
<br />
<p>
<p>
    State:@(Html.AjaxDropdown("Cities2")
        .Controller<AjaxDropdownController>()
        .Postfix("aaa")
        .Filter("1")
        .OriginalValue("1")
        .ToHtml())
</p>



